<?php
namespace app\api\controller\v1;
use think\facade\{
    Config,Request,Cache
};
use app\common\facade\{
    User
};
class Base extends \think\Controller
{
    public $sys = [];
    public $userinfo = [];
    public function __construct()
    {
        parent::__construct();
        $this->sys = Cache::get("sys_config");
        $this->checkUser();
    }

    //验签
    public function checkUser(){
        $token = input('token');
        if($token){
            $this->userinfo = User::getInfoBytoken($token);
        }
    }
}
